<!DOCTYPE html>
<head>
    <title>测试</title>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8">
    <script type="text/javascript" src="script/jquery.min.js"></script>
    <script type="text/javascript" src="script/jquery.easing.js"></script>
    <script type="text/javascript" src="script/popup.js"></script>
    <script type="text/javascript" src="script/roateImg.js"></script>
    <script type="text/javascript" src="script/drag.js"></script>
    <script type="text/javascript" src="script/define.js"></script>
</head>
<body>
    <a style="height:16px; width:80px; display:block; line-height:16px">下载</a>
    <div id="di">
        click me
    </div>
    <div>
        <div id="dg" style="width:100px; height:100px; background:red;">
        </div>
        <div id="test">
            社交（）；阿道夫阿道夫阿道夫爱人体各如果安定感风格爱的风格阿道夫
            <div>
                adf adsfasdfasdf
            </div>
            <div>
                减肥阿萨德发阿萨德发阿的说法阿萨德发安抚撒旦法违法阿萨德发艾丝凡
            </div>
        </div>
    </div>
    <div id="video" style="display:none; width:500px; height:300px;">
        <div>
            的v刹lose阿萨德阿道夫的v刹lose阿萨德阿道夫的v刹lose阿萨德阿道夫的v刹lose阿萨德阿道夫的v刹lose阿萨德阿道夫的v刹lose阿萨德阿道夫的v刹lose阿萨德阿道夫
        </div>
        <div style="text-align:center; width:500px;">
            <span class="sure">确定</span>
            <span class="cancel">取消</span>
        </div>
    </div>
    <input/><script type="text/javascript">
		
		var getStyle = function(ele,pro){
			var ownerDoc = ele.ownerDocument;
			if(ownerDoc.defaultView && ownerDoc.defaultView.getComputedStyle){
				var styles = ownerDoc.defaultView.getComputedStyle(ele,null);
				if(styles){
					return styles[pro] || styles.getPropertyValue(pro);
				}
			}
			if(ele.currentStyle){
				var styles = ele.currentStyle;
				return styles[pro];
			}
			return ele.style[pro];
		}
		
		console.log();
        
        
        var coo = newDeskPopup({
            css: {
                width: "500px",
                height: "300px",
                color: "#ffffff"
            },
            animateType: "top-bottom",
            popupId: "2-3",
            content: $("#video").show()
        });
        var startCss = {
            left: ($(window).width() - 500) / 2,
            top: -300
        }, endCss = {
            top: ($(window).height() - 300) / 2,
            opacity: "0.7"
        }
        $("#di").click(function(){
            coo.getPopup("2-3") &&
            coo.getPopup("2-3").comeOn(startCss, endCss, function(){
                console.log("asdfasdf");
            });
        });
        $("#video").delegate("span.sure", "click", function(){
            var endCss = {
                top: -300
            };
            coo.getPopup("2-3") &&
            coo.getPopup("2-3").getOut(endCss, function(){
                console.log("asdfasdf");
                //coo.destoryPopup(coo.getPopup("2-3"));
            });
            
        });
        var test = $("#test");
        
        test.click(function(){
            dragable({
                ele: $("#dg")
            })
            
        });
        $(document).keypress(function(evt){
            if (evt.keyCode == 13) {
                console.log("sfdsad");
            }
            
        });
        wky_define("wky.base.core", function(core){
            var isAnimate = function(){
                alert("isAnimating");
            }
            return {
                varVal: isAnimate
            }
        });
        wky_define("wky.base.core", function(core){
        
            var isAnimate = function(){
                alert("isAnimating");
            }
            return {
                varName: "animatings",
                varVal: isAnimate
            }
            
        });
        wky_define("wky.base.ajax", function(core){
        
            var isAnimate = function(){
                alert("isAnimatingasdfasdfas");
            }
            return {
                varName: "animatings",
                varVal: isAnimate
            }
            
        });
        
        wky.base.core.isAnimate();
    </script>
</body>
